<?php
include("include/config.inc.php");
if(!isset($_SESSION['s_activId']))
{
  header("location:checklogin.php");
}

$k=0;  
$branchArray = array();
$selectBranch = "SELECT branchId,branchName
                   FROM branch";
$selectBranchRes = mysql_query($selectBranch);
while($branchRow = mysql_fetch_array($selectBranchRes))
{
	$branchArray['branchId'][$k]   = $branchRow['branchId'];
	$branchArray['branchName'][$k] = $branchRow['branchName'];
	$k++;
}
include("./bottom.php");
$smarty->assign("branchArray",$branchArray);
$smarty->display('index.tpl');
?>
